home *** CD-ROM | disk | FTP | other *** search
/ Libris Britannia 4 / science library(b).zip / science library(b) / PROGRAMM / PASCAL / 0195.ZIP / EXISTFIL.PAS < prev    next >
Pascal/Delphi Source File  |  1984-12-21  |  812b  |  24 lines

  1. {@@@@@@@@@@@ copyright (C) 1984 by Neil J. Rubenking @@@@@@@@@@@@@@@@@@@@@@@@
  2. The purchaser of these procedures and functions may include them in COMPILED
  3. programs freely, but may not sell or give away the source text.
  4.  
  5.  
  6. @@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@}
  7.  
  8. type
  9.   old_filename_type = string[14];  {This type declaration is NOT inside the
  10.                                    INCLUDE file in order to avoid multiple
  11.                                    declarations}
  12.  
  13. {$I existfil.lib}
  14. var
  15.   name_to_test : old_filename_type;
  16. begin
  17.   WriteLn('Enter filename to test.  Include drive, if not same.');
  18.   ReadLn(name_to_test);
  19.   if exists(name_to_test) then
  20.     WriteLn(name_to_test,' exists.')
  21.   else
  22.     WriteLn(name_to_test,' does not exist.');
  23. end.
  24.